
<div class='span12'>
    <!-- HEADER -->
    <div class='row-fluid'>
        <div class='span12'>
            <div class='page-header'>
                <h1>
                    <i class='icon-cogs'></i>
                    <span>SETTINGS</span>
                </h1>
            </div>
        </div>
    </div>

    <!-- END OF HEADER -->


    <div class="row-fluid">
        <div class="span12 box bordered-box blue-border">
            <div class="box-header dark-background">
                <div class="title">LOCALIZATION SETTINGS</div>
                <div class="actions">
                    <a href="#" class="btn box-remove btn-mini btn-link"><i class="icon-remove"></i>
                    </a>
                    <a href="#" class="btn box-collapse btn-mini btn-link"><i></i>
                    </a>
                </div>
            </div>

            <div class="box-content">
                <p>
                    <small>Few function will only work if your server has a PHP version 5.1.0 or newer.</small>

                </p>

                    <form accept-charset="<?= Settings::get('en','charecter_set');?>" action="<?= URL::current(); ?>" class="form form-horizontal "
                          method="post">

                        <div>
                            <?= Form::token(); ?>
                        </div>

                        <p class="text-dark-orange">
                            <?=
                            (Session::get('message') ? Session::get('message') : '');
                            ?>
                        </p>



                        <div class="control-group">
                            <label class="control-label"> Default Timezone </label>

                            <div class="controls">
                                <select id="inputSelect" name="timezone">
                                    <option value="" selected="selected">--Select--</option>
                                    <?php foreach($timezones as $key=>$value):?>
                                    <option value="<?= $value;?>" <?= (Settings::get('en','timezone') == $value ? 'selected' : '') ;?> ><?= $value;?></option>
                                    <?php endforeach;?>
                                    </select>
                            </div>
                        </div>

                        <div class="control-group">
                            <label class="control-label"> Default Charset </label>

                            <div class="controls">
                                <select id="inputSelect" name="charecter_set">
                                    <option value="" selected="selected">--Select--</option>
                                    <?php foreach($charsets as $charsets):?>
                                        <option value="<?= $charsets['id'];?>" <?= (Settings::get('en','charecter_set') == $charsets['id'] ? 'selected' : '') ;?> ><?= $charsets['name'];?></option>
                                    <?php endforeach;?>
                                </select>
                            </div>
                        </div>

                        <hr class="hr-normal">

                        <div class="control-group">
                            <label class="control-label"> Short Date Format </label>
                            <div class="controls">
                                <input class="input-large" name="short_date_format"
                                       value="<?= Settings::get('en','short_date_format');?>" placeholder="d-m-Y"
                                       type="text" >
                            </div>
                        </div>
                        <div class="control-group">
                            <label class="control-label"> Long Date Format </label>

                            <div class="controls">
                                <input class="input-large" name="long_date_format"
                                       value="<?= Settings::get('en','long_date_format');?>" placeholder="d-m-Y h:m:s"
                                       type="text" >
                            </div>
                        </div>
                        <hr class="hr-normal">

                        <div class="control-group">
                            <label class="control-label"> Default Currency </label>
                            <div class="controls">
                                <select id="inputSelect" name="currecy_symbol" class="input-small">
                                    <option value="" selected="selected">--Select--</option>
                                    <?php foreach($currency as $key=>$value):?>
                                        <option value="<?= $value;?>" <?= (Settings::get('en','currecy_symbol') == $value ? 'selected' : '') ;?> ><?= $value;?></option>
                                    <?php endforeach;?>
                                </select>
                            </div>

                        </div>
                        <div class="control-group">
                            <label class="control-label"> Price Format (Decimals) </label>

                            <div class="controls">
                                <input class="input-mini" name="currency_decimal"
                                       value="<?= Settings::get('en','currency_decimal');?>" placeholder="2"
                                       type="text" >
                            </div>
                        </div>

                        
                        <div class="form-actions">
                            <button class="btn btn-primary" type="submit" name="btnSave" value="save"  <?php if(Config::get('application.mode')){?>onclick="alert ('Sorry! Not allowed in demo mode '); return false;" 
                                        <?}else{?>onclick="return confirm('Are you sure ?');"<?php }?>>
                                <i class="icon-save"></i>
                                Save
                            </button>

                        </div>
                    </form>


        </div>
    </div>


    <!-- END OF CONTENT -->
</div>
